package com.zhentao.day03.pm;

public class Car {
  // 1.	成员变量：颜色、价格、保修期，并增加getter/setter方法
  String color;
  double price;
  String date;

  public Car() {
  }

  public Car(String color, double price, String date) {
    this.color = color;
    this.price = price;
    this.date = date;
  }

  public String getColor() {
    return color;
  }

  public void setColor(String color) {
    this.color = color;
  }

  public double getPrice() {
    return price;
  }

  public void setPrice(double price) {
    this.price = price;
  }

  public String getDate() {
    return date;
  }

  public void setDate(String date) {
    this.date = date;
  }

  // 3.	输出所有信息的方法
  public void showInfo() {
    System.out.println("color:" + color + " price:" + price
        + " date:" + date);
  }

}
